@import '../../../../styles/dependencies/mixins/epics-dashboard';

.epic-row {
    @include epics-table;
    @include font-size(small);
    align-items: center;
    background: $color-gray100;
    border-radius: 3px;
    cursor: move;
    display: flex;
    margin-bottom: .5rem;
    padding-left: 1rem;
    position: relative;
    transition: background .2s;
    &.unfold,
    &:hover {
        background-color: $color-gray200;
        .icon-drag {
            opacity: 1;
        }
    }
    &.not-empty {
        cursor: pointer;
    }
    &.is-blocked {
        background: $color-solid-red;
    }
    &.is-closed {
        .name a {
            color: lighten($gray-light, 15%);
            text-decoration: line-through;
        }
    }
    &.unfold {
        .name {
            .icon {
                transform: rotate(0deg);
            }
        }
    }
    .fold-us {
        flex-shrink: 0;
        margin-left: .75rem;
        width: 1rem;
    }
    .name {
        align-items: center;
        display: flex;
        padding-left: 0;
        a {
            &:hover {
                .ref,
                .subject {
                    color: $color-link-primary;
                }
            }
        }
        .subject {
            color: $color-black600;
            margin-left: .25rem;
        }
        .icon {
            transform: rotate(-90deg);
            transition: all .2s;
        }
    }
    .icon-drag {
        @include svg-size(1rem);
        cursor: move;
        fill: $color-link-primary;
        left: .5rem;
        opacity: 0;
        position: absolute;
        transition: opacity .1s;
    }
    .epic-pill {
        @include font-type(regular);
        @include font-size(xsmall);
        background: $grayer;
        border-radius: 6px;
        color: $white;
        height: 12px;
        margin: 0 .5rem;
        padding: .1rem .25rem;
        width: 12px;
    }
    .status-holder {
        cursor: pointer;
        position: relative;
        button {
            align-items: center;
            background: none;
            display: flex;
            margin: 0 auto;
        }
    }
    .icon-arrow-down {
        @include svg-size(.7rem);
        fill: $gray-light;
        margin-left: .1rem;
    }
    .progress-bar,
    .progress-status {
        height: 1.5rem;
        left: 0;
        position: absolute;
        top: .25rem;
    }
    .progress-bar {
        background-color: $color-white;
        max-width: 40vw;
        padding-right: 1rem;
        width: 100%;
    }
    .progress-status {
        background-color: $color-link-primary;
        width: 10vw;
    }
    .assigned {
        align-items: center;
        display: flex;
        justify-content: center;
        img {
            border-radius: 50%;
            height: 2rem;
            overflow: hidden;
            width: 2rem;
        }
    }
    .is-unassigned {
        color: $gray-light;
    }
    .epic-statuses {
        @include popover(
            $width: 150px,
            $top: 40px,
            $right: 0,
            $arrow-width: 0
        );
        display: block;
        text-align: left;
    }
    .loading-spinner {
        height: 10px;
        width: 10px;
    }
}

.epic-stories-wrapper {
    margin-bottom: .5rem;
}
